package cn.xmkeshe.dao;

import cn.xmkeshe.model.Role;
import org.apache.ibatis.annotations.Select;

import java.util.List;
import java.util.Set;

public interface IRoleDao {

  @Select("SELECT flag FROM role WHERE rid IN (SELECT rid FROM admin_role WHERE admin_role.aid=#{aid})")
  public Set<String> findAllRoleByAdmin(String aid);

  @Select("select * from role")
  public List<Role> findAll();
}
